home *** CD-ROM | disk | FTP | other *** search
/ Chip 1996 November / Chip 11-96.iso / workshop / howto / uucp < prev    next >
Text File  |  1996-05-25  |  19KB  |  544 lines

  1.   The Linux UUCP HOWTO
  2.   Vince Skahan, <vince@victrola.wa.com>
  3.   v1.10, 6 Aug 1994
  4.  
  5.   This document describes the setup and care+feeding of UUCP under
  6.   Linux.  You need to read this if you plan to connect to remote sites
  7.   via UUCP via a modem, via a direct-connection, or via Internet.  You
  8.   probably do *not* need to read this document if don't talk UUCP.
  9.  
  10.   1.  Introduction
  11.  
  12.   The intent of this document is to answer some of the questions and
  13.   comments that appear to meet the definition of "frequently asked
  14.   questions" about UUCP software under Linux in general, and the version
  15.   in the Linux SLS and Slackware distributions in particular.
  16.  
  17.   This document and the corresponding Mail and News "HOWTO" documents
  18.   collectively supersede the UUCP-NEWS-MAIL-FAQ that has previously been
  19.   posted to comp.os.linux.announce.
  20.  
  21.   1.1.  New versions of this document
  22.  
  23.   New versions of this document will be periodically posted to
  24.   comp.os.linux.announce, comp.answers, and news.answers.  They will
  25.   also be added to the various anonymous ftp sites who archive such
  26.   information including sunsite.unc.edu:/pub/Linux/docs/HOWTO.
  27.  
  28.   1.2.  Feedback
  29.  
  30.   I am interested in any feedback, positive or negative, regarding the
  31.   content of this document via e-mail.  Definitely contact me if you
  32.   find errors or obvious omissions.
  33.  
  34.   I read, but do not necessarily respond to, all e-mail I receive.
  35.   Requests for enhancements will be considered and acted upon based on
  36.   that day's combination of available time, merit of the request, and
  37.   daily blood pressure :-)
  38.  
  39.   Flames will quietly go to /dev/null so don't bother.
  40.  
  41.   Feedback concerning the actual format of the document should go to the
  42.   HOWTO coordinator - Matt Welsh (mdw@sunsite.unc.edu).
  43.  
  44.  
  45.   1.3.  Copyright Information
  46.  
  47.   The UUCP-HOWTO is copyrighted (c)1994 Vince Skahan.
  48.  
  49.   A verbatim copy may be reproduced or distributed in any medium
  50.   physical or electronic without permission of the author.  Translations
  51.   are similarly permitted without express permission if it includes a
  52.   notice on who translated it.
  53.  
  54.   Short quotes may be used without prior consent by the author.
  55.   Derivative work and partial distributions of the UUCP-HOWTO must be
  56.   accompanied with either a verbatim copy of this file or a pointer to
  57.   the verbatim copy.
  58.  
  59.   Commercial redistribution is allowed and encouraged; however, the
  60.   author would like to be notified of any such distributions.
  61.  
  62.   In short, we wish to promote dissemination of this information through
  63.   as many channels as possible. However, we do wish to retain copyright
  64.   the HOWTO documents, and would like to be notified of any plans to
  65.   redistribute the HOWTOs.
  66.  
  67.   We further want that ALL information provided in the HOWTOS is
  68.   disseminated.  If you have questions, please contact Matt Welsh, the
  69.   Linux HOWTO coordinator, at mdw@sunsite.unc.edu, or +1 607 256 7372.
  70.  
  71.  
  72.   1.4.  Standard Disclaimer
  73.  
  74.   Of course, I disavow any potential liability for the contents of this
  75.   document.  Use of the concepts, examples, and/or other content of this
  76.   document is entirely at your own risk.
  77.  
  78.  
  79.   1.5.  Other sources of information
  80.  
  81.   1.5.1.  Linux HOWTO Documents
  82.  
  83.   There is plenty of exceptional material provided in the other Linux
  84.   HOWTO documents and from the Linux DOC project.  In particular, you
  85.   might want to take a look at the following:
  86.  
  87.  
  88.   o  the Serial Communications HOWTO
  89.  
  90.   o  the Ethernet HOWTO
  91.  
  92.   o  the Linux Networking Administration Guide
  93.  
  94.  
  95.   1.5.2.  USENET
  96.  
  97.   comp.mail.uucp can answer most of your UUCP questions
  98.  
  99.   1.5.3.  Mailing Lists
  100.  
  101.   There is a Taylor UUCP mailing list.
  102.  
  103.   To join (or get off) the list, send mail to
  104.  
  105.                 taylor-uucp-request@gnu.ai.mit.edu
  106.  
  107.  
  108.  
  109.   This request goes to a person, not to a program, so please make sure
  110.   that you include the address at which you want to receive mail in the
  111.   text of the message.
  112.  
  113.   To send a message to the list, send it to
  114.  
  115.                taylor-uucp@gnu.ai.mit.edu
  116.  
  117.  
  118.  
  119.  
  120.   1.5.4.  Books
  121.  
  122.   HDB and V2 versions of UUCP are documented in about every vendor's
  123.   documentation as well as in almost all *nix communications books.
  124.  
  125.   Taylor config files are currently only documented in the info files
  126.   provided with the sources (and in the SLS distribution hopefully).  To
  127.   read them, you can grab the nice "infosrc" program from the SLS "s"
  128.   disks and compile it.
  129.  
  130.   The following is a non-inclusive set of books that will help.
  131.  
  132.  
  133.   o  "Managing UUCP and USENET" from O'Reilly and Associates is in my
  134.      opinion the best book out there for figuring out the programs and
  135.      protocols involved in being a USENET site.
  136.  
  137.   o  "Unix Communications" from The Waite Group contains a nice
  138.      description of all the pieces (and more) and how they fit together.
  139.  
  140.   o  "Practical Unix Security" from O'Reilly and Associates has a nice
  141.      discussion of how to secure UUCP in general.
  142.  
  143.   o  "The Internet Complete Reference" from Osborne is a fine reference
  144.      book that explains the various services available on Internet and
  145.      is a great "one-stop-shopping" source for information on news,
  146.      mail, and various other Internet resources.
  147.  
  148.  
  149.   1.6.  Where *NOT* to look for help
  150.  
  151.   There is nothing "special" about configuring and running UUCP under
  152.   Linux (any more).  Accordingly, you almost certainly do *NOT* want to
  153.   be posting generic UUCP-related questions to the comp.os.linux.*
  154.   newsgroups.
  155.  
  156.   Unless your posting is truly Linux-specific (ie, "please tell me what
  157.   config file support is built into the binaries for Taylor uucp v1.04
  158.   in SLS v1.02"), you should be asking your questions in comp.mail.uucp
  159.   or on the Taylor UUCP mailing list as indicated above.
  160.  
  161.   Let me repeat that.
  162.  
  163.   There is virtually no reason to post anything uucp-related in the
  164.   comp.os.linux hierarchy any more.  There are existing newsgroups in
  165.   the comp.mail.* hierarchy to handle *ALL* your questions.
  166.  
  167.   IF YOU POST TO COMP.OS.LINUX.* FOR NON-LINUX-SPECIFIC QUESTIONS, YOU
  168.   ARE LOOKING IN THE WRONG PLACE FOR HELP.  THE UUCP EXPERTS HANG OUT IN
  169.   THE PLACES INDICATED ABOVE AND GENERALLY DO NOT RUN LINUX.
  170.  
  171.   POSTING TO THE LINUX HIERARCHY FOR NON-LINUX-SPECIFIC QUESTIONS WASTES
  172.   YOUR TIME AND EVERYONE ELSE'S AND IT FREQUENTLY DELAYS YOU FROM
  173.   GETTING THE ANSWER TO YOUR QUESTION.
  174.  
  175.  
  176.   2.  Hardware Requirements
  177.  
  178.  
  179.   There are no specific hardware requirements for UUCP under Linux.
  180.   Basically any Hayes-compatible modem works painlessly with UUCP.
  181.  
  182.   In most cases, you'll want the fastest modem you can afford.  In
  183.   general, you want to have a 16550 UART on your serial board or built
  184.   into your modem to handle speeds of above 9600 baud.
  185.  
  186.   If you don't know what that last sentence means, please consult the
  187.   comp.dcom.modems group or the various fine modem and serial
  188.   communications FAQs and periodic postings on USENET.
  189.  
  190.  
  191.   3.  Getting UUCP
  192.  
  193.   Taylor UUCP (current version 1.05) is available on prep.ai.mit.edu in
  194.   source form and in various Linux distributions in binary form.
  195.  
  196.   The newspak-2.2.tar.z distribution contains config files and readme
  197.   files related to building uucp, news, and mail software under Linux
  198.   from the various freely-available sources.  It can usually be found on
  199.   sunsite.unc.edu in the directory /pub/Linux/system/Mail.
  200.  
  201.  
  202.   4.  Installing the Software
  203.  
  204.   (Much of this section is taken verbatim from the README file in the
  205.   Taylor UUCP v1.05 sources - it's provided here so I can help you
  206.   "rtfm" instead of just telling you to do so)
  207.  
  208.   Detailed compilation instructions are in uucp.texi in the sources.
  209.  
  210.   You can grab "known good" conf.h and policy.h files for Linux from the
  211.   newspak distribution referred to in the "other sources of information"
  212.   section above.  In that case, you can probably go right to typing
  213.   "make".
  214.  
  215.  
  216.   4.1.  Extracting the compressed sources
  217.  
  218.   To extract a gzip'd tar archive, I do the following:
  219.  
  220.                   gunzip -c filename.tar.z | tar xvf -
  221.  
  222.  
  223.   A "modern" tar can just do a:
  224.  
  225.                  tar -zxvf filename.tgz
  226.  
  227.  
  228.  
  229.   4.2.  Edit Makefile.in to set installation directories.
  230.  
  231.   Here, I set "prefix" to "/usr" rather than the default of "/usr/local"
  232.  
  233.  
  234.   4.3.  Run "configure"
  235.  
  236.   Type "sh configure".
  237.  
  238.   The configure script will compile a number of test programs to see
  239.   what is available on your system and will calculate many things.
  240.  
  241.   The configure script will create conf.h from conf.h.in and Makefile
  242.   from Makefile.in.  It will also create config.status, which is a shell
  243.   script which actually creates the files.
  244.  
  245.  
  246.   o  Rather than editing the Makefile.in file in the sources as
  247.      indicated above, you can get the same effect by:
  248.  
  249.              "configure --prefix=/usr/lib"
  250.  
  251.  
  252.  
  253.   4.4.  Configure the future setup of the software
  254.  
  255.  
  256.   4.4.1.  Examine conf.h and Makefile to make sure they're right.
  257.  
  258.   I took the defaults
  259.  
  260.   4.4.2.  Edit policy.h for your local system.
  261.  
  262.  
  263.   o  - set the type of lockfiles you want (HAVE_HDB_LOCKFILES)
  264.  
  265.   o  - set the type of config files you want built in
  266.      (HAVE_TAYLOR_CONFIG, HAVE_V2_CONFIG, HAVE_HDB_CONFIG)
  267.  
  268.   o  - set the type of spool directory structure you want (SPOOLDIR_HDB)
  269.  
  270.   o  - set the type of logging you want (HAVE_HDB_LOGGING)
  271.  
  272.   o  - set the default search path for commands (I added /usr/local/bin
  273.      to mine)
  274.  
  275.   4.5.  Compile and install the software
  276.  
  277.  
  278.   o  Type "make".
  279.  
  280.   o  Use "uuchk | more" to check configuration files.  You can use
  281.      "uuconv" to convert between configuration file formats.
  282.  
  283.   o  Type "make install" to install.
  284.  
  285.   4.6.  Set up the config files
  286.  
  287.   I'd recommend you start by taking the attached known-good config files
  288.   for HDB mode and installing them.
  289.  
  290.   o  Make sure that the Permissions file indicates exactly where rmail
  291.      and rnews are to be found if you put them anywhere other than in
  292.      the path you specified in policy.h
  293.  
  294.   o  Make sure that your Devices files matches the actual location of
  295.      your modem (cua1=COM2 in the examples)
  296.  
  297.   o  Edit the Systems file to set up the system(s) you talk to with
  298.      their speed, phone number, username, and password.
  299.  
  300.      *PROTECT THIS FILE AGAINST WORLD READ*
  301.  
  302.   o  Set up the Permissions file and add a set of lines for each site
  303.      you talk to.  For security reasons, it's recommended to make sure
  304.      they each have a separate account (if you allow dialin) and home
  305.      directory so you can track things.
  306.  
  307.  
  308.   4.7.  Give it a try
  309.  
  310.  
  311.  
  312.           /usr/lib/uucp/uucico -r 1 -x 9 -s remote_system_name
  313.  
  314.  
  315.  
  316.   The -x 9 will have maximum debugging information written to the
  317.   /usr/spool/uucp/.Admin/audit.local file for help in initial setup.
  318.  
  319.   I normally run -x 4 here since that level logs details that help me
  320.   with login problems.  Obviously, this contains cleartext information
  321.   from your Systems file (account/password) so protect it against world-
  322.   read.
  323.  
  324.  
  325.   o  from Pierre.Beyssac@emeraude.syseca.fr
  326.  
  327.      Taylor has more logging levels.  Use -x all to get the highest
  328.      level possible.
  329.  
  330.      Also, do a "tail -f /usr/spool/uucp/.Admin/audit.local" while
  331.      debugging to watch things happen on the fly.
  332.  
  333.   4.8.  It doesn't work - now what ?
  334.  
  335.   In general, you can refer to the documentation mentioned above if
  336.   things don't work.  You can also refer to your more experienced UUCP
  337.   neighbors for help.  Usually, it's something like a typo anyway.
  338.  
  339.  
  340.   5.  Frequently Asked Questions about Linux UUCP
  341.  
  342.  
  343.  
  344.   5.1.  Why is my binary of uucp configured in HDB rather than "Taylor"
  345.   mode?
  346.  
  347.   (religious mode on - I know some people are just as religious about
  348.   "ease of use" as I am about "being standard".  That's why they make
  349.   source code you can build your own from :-) )
  350.  
  351.   Because IMHO it's the de-facto standard UUCP implementation at this
  352.   time.  There are thousands of sites with experienced admins and there
  353.   are many places you can get incredibly good information concerning the
  354.   HDB setup.
  355.  
  356.   The uucp-1.04 that's in SLS 1.02 and later has all three modes of
  357.   config files built in.  While I can't test it, I did "rtfm" and Ian
  358.   Taylor tells me that it should work.
  359.  
  360.   The search order for config files is Taylor then V2 (L.sys)  then HDB.
  361.   Use the uuconv utility in /usr/lib/uucp to convert config files from
  362.   one mode to another.
  363.  
  364.   If you can't wait, grab the sources for uucp and specify
  365.   HAVE_BNU_CONFIG, HAVE_V2_CONFIG *and* HAVE_TAYLOR_CONFIG in the
  366.   policy.h file and type "make".
  367.  
  368.   The following workaround is ugly, but it does work, if you want to run
  369.   Taylor configs from binaries that don't have it built in.
  370.  
  371.   o  From mbravo@tctube.spb.su (Michael E. Bravo)
  372.  
  373.      - add  "-I /usr/local/lib/uucp/config" to _every_ invocation of
  374.      whatever program in uucp package
  375.  
  376.   5.2.  Why do I get "timeout" on connections when I upgraded to
  377.   uucp-1.04 ?
  378.  
  379.  
  380.   o  from Ed Carp - erc@apple.com
  381.  
  382.      If you use a "Direct" device in the Devices file, there's now a 10
  383.      second timeout compiled in.  Make the name of the Device anything
  384.      other than "Direct".  If you tweak the example /usr/lib/uucp files
  385.      provided with SLS, you won't have problems with this one.
  386.  
  387.   o  from Greg Naber - greg@squally.halcyon.com
  388.  
  389.      If you get chat script timeouts, you can tweak the sources by
  390.      editing at line 323 in uuconf/syssub.c and changing the default
  391.      timeouts from 10 seconds to something larger.
  392.  
  393.   o  from Ed Rodda - ed@orca.wimsey.bc.ca
  394.  
  395.      If you get chat script timeouts, typically connecting to other
  396.      Taylor sites, a pause after login can fix this.
  397.      feed Any ACU,ag 38400 5551212 ogin: \c\d "" yourname word: passwd
  398.  
  399.  
  400.  
  401.   o  from Dr. Eberhard W. Lisse - el@lisse.NA
  402.  
  403.      Some kernels experience modems hanging up after a couple of
  404.      seconds.  The following patch sent by Ian Taylor might help.
  405.  
  406.      *** conn.c.orig Mon Feb 22 20:25:24 1993
  407.      --- conn.c      Mon Feb 22 20:33:10 1993
  408.      ***************
  409.      *** 204,209 ****
  410.      --- 204,212 ----
  411.  
  412.           /* Make sure any signal reporting has been done before we set
  413.             fLog_sighup back to TRUE.  */
  414.      +   /* SMR: it seems to me if we don't care about SIGHUPS, we should clear
  415.      +      the flag before we return  */
  416.      +   afSignal[INDEXSIG_SIGHUP] = FALSE;
  417.          ulog (LOG_ERROR, (const char *) NULL);
  418.          fLog_sighup = TRUE;
  419.  
  420.  
  421.  
  422.   5.3.  Why doesn't HDB anonymous uucp seem to work ?
  423.  
  424.   The SLS anonymous uucp only works in Taylor mode because it's compiled
  425.   with HAVE_TAYLOR_CONFIG.  If you want to do anon uucp in HDB mode,
  426.   you'll have to recompile the sources with just HDB defined.  Ian
  427.   Taylor is considering which way to deal with this "feature".
  428.  
  429.   Also, Taylor in HDB mode seems to be sensitive to white space and
  430.   blank lines.  To be safe, make sure that there are no blank lines or
  431.   trailing spaces in the Permissions file.
  432.  
  433.   Lastly, make sure that you have a file called remote.unknown in
  434.   /usr/lib/uucp and that it's *NOT* executable.  See the O'Reilly+Assoc
  435.   book "Managing UUCP and USENET" for details regarding this file.
  436.  
  437.  
  438.   5.4.  What does "no matching ports found" mean ?
  439.  
  440.   In all probability, you are attempting to use a device
  441.   (/usr/lib/uucp/Devices) that doesn't exist, or the device you've
  442.   specified in the /usr/lib/uucp/Systems file doesn't match up with any
  443.   valid devices in the Devices file.
  444.  
  445.   Following this are *sanitized* versions of my working Taylor 1.05 HDB
  446.   config files that you can plug in and use.
  447.  
  448.   note the "ACU" in the Systems ?  That tells which "port" to use in
  449.   Devices
  450.  
  451.   see the "scout" word in Systems ?  That tells which dialer to use in
  452.   Dialers.
  453.  
  454.   If you had a ACU port, but none that matched the specified dialer on
  455.   the same line in Systems, you'll get that message.
  456.  
  457.  
  458.   5.5.  What are known good config files for HDB mode ?
  459.  
  460.   The following are "known-good" config files for Taylor 1.05 under
  461.   Linux in HoneyDanBer mode.  They work on kernels of 0.99-8 or later.
  462.   All files should be in /usr/lib/uucp unless you've tweaked the sources
  463.   to put the uucp library elsewhere.
  464.  
  465.   If you *HAVE* put things in non-standard places, be aware that things
  466.   like sendmail might get very confused. You need to ensure that all
  467.   communications-related programs agree on your idea of "standard"
  468.   paths.
  469.  
  470.   If you're running a kernel of 0.99-7 or earlier, change "cua1" to
  471.   "ttyS1".
  472.  
  473.  
  474.   #------------- Devices -------------
  475.   # make sure the device (cua1 here) matches your system
  476.   # cua1 = COM2
  477.   #
  478.   # here "scout" is the Digicom Scout Plus 19.2 modem I use
  479.   # tbfast etc. is for a Telebit Trailblazer Plus modem's various speeds
  480.   #
  481.   ACU cua1 - 19200 scout
  482.   ACU cua1 - 9600 tbfast
  483.   ACU cua1 - 1200 tbslow
  484.   ACU cua1 - 2400 tbmed
  485.  
  486.   #------------- dialers --------------
  487.   # note the setting of the Trailblazer registers "on the fly"
  488.   # "scout" is a Digicom Scout Plus (Hayes-like) modem I use here
  489.   #
  490.   scout   =W-,    "" ATM0DT\T CONNECT
  491.   tbfast  =W-,    "" A\pA\pA\pT OK ATS50=255DT\T CONNECT\sFAST
  492.   tbslow  =W-,    "" A\pA\pA\pT OK ATS50=2DT\T CONNECT\s1200
  493.   tbmed   =W-,    "" A\pA\pA\pT OK ATS50=3DT\T CONNECT\s2400
  494.  
  495.   #-------------- Systems -------------
  496.   # this is a very generic entry that will work for most systems
  497.   #
  498.   # the Any;1 means that you can call once per minute with using -f (force)
  499.   # the ACU,g means force "g" protocol rather than Taylor's default "i"
  500.   #
  501.   fredsys Any;1 ACU,g 19200 scout5555555 "" \r ogin:--ogin: uanon word: uanon
  502.  
  503.   #-------------------------------- Permissions -------------------------
  504.  
  505.   # Taylor UUCP in HDB mode appears to be sensitive to blank lines.
  506.   # Make sure all Permissions lines are real or commented out.
  507.   #
  508.   # this is a anonymous uucp entry
  509.   #
  510.   LOGNAME=nuucp MACHINE=OTHER \
  511.   READ=/usr/spool/uucp/nuucp \
  512.   WRITE=/usr/spool/uucp/nuucp \
  513.   SENDFILES=yes REQUEST=yes \
  514.   COMMANDS=/bin/rmail
  515.   #
  516.   # this is a normal setup for a remote system that talks to us
  517.   # note the absolute path to rnews since this site puts things
  518.   # in locations that aren't "standard"
  519.   #
  520.   LOGNAME=fredsys MACHINE=fredsys \
  521.   READ=/usr/spool/uucp/fredsys:/usr/spool/uucp/uucppublic:/files \
  522.   WRITE=/usr/spool/uucp/fredsys:/usr/spool/uucppublic \
  523.   SENDFILES=yes REQUEST=yes \
  524.   COMMANDS=/bin/rmail:/usr/local/lib/news/bin/rnews
  525.   #----------------------------------------------------------------------
  526.  
  527.  
  528.  
  529.   5.6.  Getting uucico to call alternate numbers
  530.  
  531.   The new v1.05 has an added '-z' switch to uucico that will try
  532.   alternate numbers for a remote system.
  533.  
  534.   6.  Acknowledgements
  535.  
  536.  
  537.   The following people have helped in the assembly of the information
  538.   (and experience) that helped make this document possible:
  539.  
  540.   Ed Carp, Steve Robbins, Ian Taylor, Greg Naber, Matt Welsh, Pierre
  541.   Beyssac
  542.  
  543.   If I forgot anybody, my apologies.
  544.